Dynomotion

Group: DynoMotion Message: 5696 From: bradodarb Date: 9/22/2012
Subject: Axis Group Stopping
Hello Tom,


I am flushing out the functionality of the .Net Axis group object.

We are performing a sequence that goes a little something like this:


------------>Step one, move to initial position

MoveTo() (which calls coordmotion straightfeed)

Then WaitforMotionComplete()



Which calls this on the c++ side:

>WaitForMoveXYZABCFinished()




------------->Step two, perform profile operation
Then I proceed to add line and arc segments....


The problem is that the WaitforMotionComplete() is returning true before it is complete in my initial move, so the profiling segments start to execute prior to achieving the start position.


This is very apparent when I go to repeat the operation. Instead of going back to the requested stop position, it for all intents and purposes runs the profile from where it last stopped (less the execution time for the DLL calls which results in a few .00001's of offset)



Can you have a look at this method and see where I buggered it up, or perhaps suggest another method to use rather than

CM_dll->WaitForMoveXYZABCFinished();

Like maybe

CM_dll->WaitForSegmentsFinished(NoErrorOnDisable);


....I will try that in the mean time


Thanks!

-Brad Murry
Group: DynoMotion Message: 5698 From: Tom Kerekes Date: 9/22/2012
Subject: Re: Axis Group Stopping
Hi Brad,
 
No.  WaitForMoveXYZABCFinished is intended for used after a StraightTraverse movement (non-coordinated motion).
 
After defining a coordinated motion path of lines and arcs:
 
FlushSegments()  - causes all segments to be downloaded and executing
 
then
 
WaitForSegmentsFinished() - wait until all segments have finished executing
 
Regards
TK 

 
From: bradodarb <bradodarb@...>
To: DynoMotion@yahoogroups.com
Sent: Saturday, September 22, 2012 8:56 AM
Subject: [DynoMotion] Axis Group Stopping

 
Hello Tom,

I am flushing out the functionality of the .Net Axis group object.

We are performing a sequence that goes a little something like this:

------------>Step one, move to initial position

MoveTo() (which calls coordmotion straightfeed)

Then WaitforMotionComplete()

Which calls this on the c++ side:

>WaitForMoveXYZABCFinished()

------------->Step two, perform profile operation
Then I proceed to add line and arc segments....

The problem is that the WaitforMotionComplete() is returning true before it is complete in my initial move, so the profiling segments start to execute prior to achieving the start position.

This is very apparent when I go to repeat the operation. Instead of going back to the requested stop position, it for all intents and purposes runs the profile from where it last stopped (less the execution time for the DLL calls which results in a few .00001's of offset)

Can you have a look at this method and see where I buggered it up, or perhaps suggest another method to use rather than

CM_dll->WaitForMoveXYZABCFinished();

Like maybe

CM_dll->WaitForSegmentsFinished(NoErrorOnDisable);

....I will try that in the mean time

Thanks!

-Brad Murry




Group: DynoMotion Message: 5699 From: bradodarb Date: 9/22/2012
Subject: Re: Axis Group Stopping
Hmm....


So now I am calling


_Controller.CoordMotion.FlushSegments();
_Controller.CoordMotion.WaitForSegmentsFinished(true);
_Controller.CoordMotion.WaitForMoveXYZABCFinished();

(to make sure feed and traversal motion is complete)

But it still returns before motion is actually complete.


Any thoughts?

-Brad Murry


--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Brad,
>  No.  WaitForMoveXYZABCFinished is intended for used after a StraightTraverse movement (non-coordinated motion).
>  
> After defining a coordinated motion path of lines and arcs:
>  FlushSegments()  - causes all segments to be downloaded and executing
>  
> then
>  WaitForSegmentsFinished() - wait until all segments have finished executing
>  
> Regards
> TK 
>
>  
>
> ________________________________
> From: bradodarb <bradodarb@...>
> To: DynoMotion@yahoogroups.com
> Sent: Saturday, September 22, 2012 8:56 AM
> Subject: [DynoMotion] Axis Group Stopping
>
>
>
>  
>
> Hello Tom,
>
> I am flushing out the functionality of the .Net Axis group object.
>
> We are performing a sequence that goes a little something like this:
>
> ------------>Step one, move to initial position
>
> MoveTo() (which calls coordmotion straightfeed)
>
> Then WaitforMotionComplete()
>
> Which calls this on the c++ side:
>
> >WaitForMoveXYZABCFinished()
>
> ------------->Step two, perform profile operation
> Then I proceed to add line and arc segments....
>
> The problem is that the WaitforMotionComplete() is returning true before it is complete in my initial move, so the profiling segments start to execute prior to achieving the start position.
>
> This is very apparent when I go to repeat the operation. Instead of going back to the requested stop position, it for all intents and purposes runs the profile from where it last stopped (less the execution time for the DLL calls which results in a few .00001's of offset)
>
> Can you have a look at this method and see where I buggered it up, or perhaps suggest another method to use rather than
>
> CM_dll->WaitForMoveXYZABCFinished();
>
> Like maybe
>
> CM_dll->WaitForSegmentsFinished(NoErrorOnDisable);
>
> ....I will try that in the mean time
>
> Thanks!
>
> -Brad Murry
>
Group: DynoMotion Message: 5700 From: Tom Kerekes Date: 9/22/2012
Subject: Re: Axis Group Stopping
Hi Brad,

The only think I can think of is that there is some error such as one of the axes defined in the coordinate system is disabled.

The function: WaitForSegmentsFinished

basically does a "CheckDoneBuf" which returns a 

0=not done
1=done
-1=error axis disabled

The flag passed in determines how a disabled axis is treated.  flag=true just returns silently immediately without doing anything special with no error code.  flag=false will set the global Abort flag and return an error.

It doesn't look like the .NET interface checks or returns the error code.

Regards
TK


Group: DynoMotion Message: 5707 From: bradodarb Date: 9/24/2012
Subject: Re: Axis Group Stopping
Hello Tom,

I updated that call to do something useful with the return result.

MotionComplete returns an enum representing the states you described, and WaitForMotionDone now waits for :Done to be returned.



I still see no change in behavior. I am going to look at the Interpreter code to see how you are making the calls there and I also need to debug better locally as the machine I am trying to diagnose will not run visual studios properly.


-Brad Murry

--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Brad,
>
> The only think I can think of is that there is some error such as one of the axes defined in the coordinate system is disabled.
>
> The function: WaitForSegmentsFinished
>
> basically does a "CheckDoneBuf" which returns a 
>
> 0=not done
> 1=done
> -1=error axis disabled
>
> The flag passed in determines how a disabled axis is treated.  flag=true just returns silently immediately without doing anything special with no error code.  flag=false will set the global Abort flag and return an error.
>
> It doesn't look like the .NET interface checks or returns the error code.
>
> Regards
> TK
>
>
>
> ________________________________
> From: bradodarb <bradodarb@...>
> To: DynoMotion@yahoogroups.com
> Sent: Saturday, September 22, 2012 10:21 AM
> Subject: [DynoMotion] Re: Axis Group Stopping
>
>
>  
>
> Hmm....
>
> So now I am calling
>
> _Controller.CoordMotion.FlushSegments();
> _Controller.CoordMotion.WaitForSegmentsFinished(true);
> _Controller.CoordMotion.WaitForMoveXYZABCFinished();
>
> (to make sure feed and traversal motion is complete)
>
> But it still returns before motion is actually complete.
>
> Any thoughts?
>
> -Brad Murry
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Brad,
> >  No.  WaitForMoveXYZABCFinished is intended for used after a StraightTraverse movement (non-coordinated motion).
> >  
> > After defining a coordinated motion path of lines and arcs:
> >  FlushSegments()  - causes all segments to be downloaded and executing
> >  
> > then
> >  WaitForSegmentsFinished() - wait until all segments have finished executing
> >  
> > Regards
> > TK 
> >
> >  
> >
> > ________________________________
> > From: bradodarb <bradodarb@>
> > To: DynoMotion@yahoogroups.com
> > Sent: Saturday, September 22, 2012 8:56 AM
> > Subject: [DynoMotion] Axis Group Stopping
> >
> >
> >
> >  
> >
> > Hello Tom,
> >
> > I am flushing out the functionality of the .Net Axis group object.
> >
> > We are performing a sequence that goes a little something like this:
> >
> > ------------>Step one, move to initial position
> >
> > MoveTo() (which calls coordmotion straightfeed)
> >
> > Then WaitforMotionComplete()
> >
> > Which calls this on the c++ side:
> >
> > >WaitForMoveXYZABCFinished()
> >
> > ------------->Step two, perform profile operation
> > Then I proceed to add line and arc segments....
> >
> > The problem is that the WaitforMotionComplete() is returning true before it is complete in my initial move, so the profiling segments start to execute prior to achieving the start position.
> >
> > This is very apparent when I go to repeat the operation. Instead of going back to the requested stop position, it for all intents and purposes runs the profile from where it last stopped (less the execution time for the DLL calls which results in a few .00001's of offset)
> >
> > Can you have a look at this method and see where I buggered it up, or perhaps suggest another method to use rather than
> >
> > CM_dll->WaitForMoveXYZABCFinished();
> >
> > Like maybe
> >
> > CM_dll->WaitForSegmentsFinished(NoErrorOnDisable);
> >
> > ....I will try that in the mean time
> >
> > Thanks!
> >
> > -Brad Murry
> >
>
Group: DynoMotion Message: 5708 From: Tom Kerekes Date: 9/24/2012
Subject: Re: Axis Group Stopping
Hi Brad,
 
You might try running KMotion.exe concurrently with your App and typing CheckDoneBuf on the Console while the motion is in progress to see whether or not the basic status is valid.
 
Regards
TK